
public class Euler025 {

	public static void main(String[] args) {

//		BigNumber f1 = BigNumber.ONE;
//		BigNumber f2 = BigNumber.ONE;
//		int index = 2;
//		BigNumber f3;
		final long start = System.currentTimeMillis();
//		do {
//			f3 = f1.addBigNumber(f2);
//			f1 = f2;
//			f2 = f3;
//			index++;
//		} while (f3.getLength() < 1000);
		int i = 1;
		double temp = 1;
		final double g = (Math.sqrt(5) + 1) / 2;
		while(temp < 999){
			i++;
			temp = i * Math.log10(g) + Math.log10(1/Math.sqrt(5));			
		}
		System.out.println(i);
		System.out.println("End after: " + (System.currentTimeMillis() - start));
//		System.out.println("index: " + index);
//		System.out.println("Pre: " + f1 + "\tCurrent: " + f2);
	}
}
